import {ORDERS} from '../consts.js'
import axios from '../axios.js'

export default{
    getOrders(params){
        return axios({
            url:ORDERS +'/getAllOrders',
            method:'get',
            params
        })
    },
//获取退保订单
    getSurrenderOrders(){
        return axios({
            url:ORDERS +'/getSurrenderOrders',
            method:'get',
            
        })
    },
    //同意退保
    handelSurrenderOrders(){
        return axios({
            url:ORDERS +'/handelSurrenderOrders',
            method:'post',
            
        })
    },
      //拒绝退保
      refuseSurrenderOrders(){
        return axios({
            url:ORDERS +'/refuseSurrenderOrders',
            method:'post',
            
        })
    },

    delOrdersById(data){
        return axios({
            url:ORDERS +'/delOrdersById',
            method:'post',
            data
        })
    },

    getOneOrderById(data){
        return axios({
            url:ORDERS +'/getOneOrderById',
            method:'post',
            data
        })
    },

    getSaleManOrder(data){
        return axios({
            url:ORDERS +'/getSaleManOrder',
            method:'post',
            data
        })
    },

    updateOrderBySaleMan(data){
        return axios({
            url:ORDERS +'/updateOrderBySaleMan',
            method:'post',
            data
        })
    },
}